import List from "../../../controls/lists";
import NoticeList from "../../../controls/lists/notice";
import TabService from "./../../tabservice";

class NoticeService extends TabService {
	defaultData() {
		let info = {
			link: "",
			tabs: [
				{
					name: "欢迎新成员",
					active: true,
					type: List,
					option: {
						url: "/api/lgb/app/lgb/noticeinfo/queryPage",
						type: NoticeList,
						parameter: {
							lbDm: 'hyxcy'
						}
					}
				},
				{
					name: "支部工作",
					active: false,
					type: List,
					option: {
						url: "/api/lgb/app/lgb/noticeinfo/queryPage",
						type: NoticeList,
						parameter: {
							lbDm: 'zbgz'
						}
					}
				},
				{
					name: "其他事项",
					active: false,
					type: List,
					option: {
						url: "/api/lgb/app/lgb/noticeinfo/queryPage",
						type: NoticeList,
						parameter: {
							lbDm: 'qtsx'
						}
					}
				},
				{
					name: "追忆与思念",
					active: false,
					type: List,
					option: {
						url: "/api/lgb/app/lgb/noticeinfo/queryPage",
						type: NoticeList,
						parameter: {
							lbDm: 'zysy'
						}
					}
				}
			]
		};
		this.setTabs(info.tabs);
		return info;
	}

	onupdate(current, data) {
		Object.assign(current, data);
	}
}

export default NoticeService;